package com.example.waimai.util;

import java.sql.Timestamp;
import java.text.SimpleDateFormat;
import java.util.Date;

public class TimeStampFormatUtil {

    public static Timestamp getCurrentTime(){
        SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
        String time = format.format(new Date());
        Timestamp timestamp = Timestamp.valueOf(time);
        return timestamp;
    }
}
